package com.example.news.service;

import com.example.news.pojo.Book;
import com.example.news.pojo.Category;
import com.example.news.pojo.PageResult;
import com.example.news.pojo.Publisher;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface BookService {
    PageResult<Book> getAllBooks(Integer currentPage, Integer publisherId);
    List<Publisher> getAllPublisher();
    List<Category> getAllCategory();
    Integer addBook(Book book, List<Integer> categoryIdList);
    Integer addBookRelationInfo(Integer bookId, List<Integer> categoryIdList);
    Book findBookById(Integer bookId);
    Integer delBookRelationInfo(Integer bookId);
    Integer updateBookInfo(Book book);
}
